﻿<UserControl x:Class="SolutionFramework.Controls.ExceptionControl"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    mc:Ignorable="d"
    Height="400" Width="600"
    d:DesignHeight="300" d:DesignWidth="400" xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" Background="Black">
    
    <Grid x:Name="LayoutRoot">
        <Grid.RowDefinitions>
            <RowDefinition Height="45" />
            <RowDefinition Height="22" />
            <RowDefinition Height="29" />
            <RowDefinition Height="22" />
            <RowDefinition Height="*" />
            <RowDefinition Height="38" />
        </Grid.RowDefinitions>
        <TextBox Grid.Row="0" Name="MessageText" Margin="3,3,3,3" FontWeight="Bold" IsReadOnly="True" TextWrapping="Wrap" />
        <sdk:Label Grid.Row="1" Height="14" HorizontalAlignment="Left" Margin="3,5,3,1" Name="label2" VerticalAlignment="Top" Width="120" Content="Source:" />
        <Border Grid.Row="2" BorderBrush="CadetBlue" BorderThickness="1" Margin="0,0,0,0" Name="border1">
            <TextBox Margin="3,3,3,3" Name="SourceText" IsReadOnly="True" />
        </Border>
        <sdk:Label Grid.Row="3" Height="14" HorizontalAlignment="Left" Margin="3,5,3,1" Name="label3" Width="120" Content="Stack Trace:" />
        <Border Grid.Row="4" BorderBrush="CadetBlue" BorderThickness="1" Margin="0,0,0,0"  Name="border2">
            <ScrollViewer Margin="3,3,3,3" Name="ScrollViewer" Grid.Row="4" MaxHeight="300" VerticalScrollBarVisibility="Visible" HorizontalScrollBarVisibility="Disabled">
                <TextBox Margin="0,0,10,0" Name="StackTraceText" TextWrapping="Wrap" IsReadOnly="True" />
            </ScrollViewer>
        </Border>
        <Grid Grid.Row="5">
            <Grid.ColumnDefinitions>
                <ColumnDefinition />
                <ColumnDefinition />
            </Grid.ColumnDefinitions>
            <HyperlinkButton Content="Inner Exception" Grid.Column="0" Margin="6,6,6,6" Name="cmdInnerException" Click="cmdInnerException_Click" />
            <HyperlinkButton HorizontalAlignment="Right" Content="View Log" Grid.Column="1" Margin="6,6,6,6" Name="cmdViewLog" Click="cmdViewLog_Click" />
        </Grid>
        <Grid.Background>
            <LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5">
                <GradientStop Color="White" Offset="0" />
                <GradientStop Color="AliceBlue" Offset="1" />
            </LinearGradientBrush>
        </Grid.Background>
    </Grid>
</UserControl>
